package main

import (
	"context"
	"fmt"
	"google.golang.org/grpc"
	"log"
	"selfService/兴趣相关/service/user_inter_mid"
)

func main() {
	conn,err:=grpc.Dial("localhost:8081",grpc.WithInsecure())
	if err!=nil{
		log.Fatal(err)
	}
	defer conn.Close()
	prodClient:=user_inter_mid.NewInterestServiceClient(conn)
	//  prodRes,err:= prodClient.GetProdStock(context.Background(),&service.ProdRequest{ProdId: 12}) // 请求一个
	prodRes,err:= prodClient.ChangeSelfInterestById(context.Background(),&user_inter_mid.ChangeInterestRequest{Id: "１ｗｗｗ",Changeid: "2"}) // 请求一个
	if err!=nil{
		log.Fatal(err)
	}
	fmt.Println(prodRes.State)
}
